If Menu_OptionsSelection(MID_SHOW_SCRAMMBLING).Checked Then R = BitBlt(Pic_Work.Hdc, Pieces(Priority(I)).X, Pieces(Priority(I)).Y, PieceWidth, PieceHeight, Pic_PuzzleImage.Hdc, Pieces(Priority(I)).X, Pieces(Priority(I)).Y, SRCCOPY)
Next I
If Not Menu_OptionsSelection(MID_SHOW_SCRAMMBLING).Checked Then Pic_Work.Refresh
End Sub
Sub Solve_Puzzle ()
Menu_Hint.Enabled = FALSE
For I = 0 To TotalPieces
Priority(I) = I
Pieces(I).X = Pieces(I).HomeX
Pieces(I).Y = Pieces(I).HomeY
Next I
Restore_Bitmap
End Sub
Sub Animate_Puzzle ()
Menu_Hint.Enabled = FALSE
Menu_File.Enabled = FALSE
Menu_Options.Enabled = FALSE
Menu_Pieces.Enabled = FALSE
Menu_Hint.Enabled = FALSE
Menu_Stop.Visible = TRUE
For I = 0 To TotalPieces
If (Pieces(Priority(0)).X <> Pieces(Priority(0)).HomeX) Or (Pieces(Priority(0)).Y <> Pieces(Priority(0)).HomeY) Then
If Pic_Work.Visible Then Pic_Window.Line (0, 0)-(Pic_Work.Left + Pic_Work.Width + 2, Pic_Work.Top + Pic_Work.Height + 2), (Not Pic_Window.Backcolor) And &HFFFFFF, B
End Sub
Sub Outline_Circles_In_Squares ()
Dim Radius As Single
If PieceWidth < PieceHeight Then Radius = PieceWidth / 2 - 5 Else Radius = PieceHeight / 2 - 5
For Y = 0 To PuzzleSize - 1
For X = 0 To PuzzleSize - 1
Pic_Bitmap.Line (X * PieceWidth, Y * PieceHeight)-(X * PieceWidth + PieceWidth - 1, Y * PieceHeight + PieceHeight - 1), , B